{
 "cells": [
  {
   "cell_type": "markdown",
   "id": "6633ab13",
   "metadata": {},
   "source": [
    "1. `read_table()`\n",
    "2. `read_csv()`\n",
    "3. `read_excel()`\n",
    "4. `to_csv()`\n",
    "5. `to_excel()`"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "id": "bff1dcf0",
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "id": "7ddf91d0",
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.microsoft.datawrangler.viewer.v0+json": {
       "columns": [
        {
         "name": "index",
         "rawType": "int64",
         "type": "integer"
        },
        {
         "name": "0",
         "rawType": "object",
         "type": "string"
        },
        {
         "name": "1",
         "rawType": "object",
         "type": "string"
        },
        {
         "name": "2",
         "rawType": "float64",
         "type": "float"
        },
        {
         "name": "3",
         "rawType": "float64",
         "type": "float"
        },
        {
         "name": "4",
         "rawType": "object",
         "type": "string"
        },
        {
         "name": "5",
         "rawType": "object",
         "type": "string"
        }
       ],
       "ref": "2370e7d4-a165-47b8-8864-2e102e1f04e9",
       "rows": [
        [
         "0",
         "S1402048",
         "2014-11-04 08:44:46",
         null,
         "1.2257903137349373e+17",
         "221.205.98.55",
         "单点登录研究生系统成功！"
        ],
        [
         "1",
         "S1411023",
         "2014-11-04 08:45:06",
         null,
         "1.2257903137349373e+17",
         "183.184.226.205",
         "单点登录研究生系统成功！"
        ],
        [
         "2",
         "S1402048",
         "2014-11-04 08:46:39",
         null,
         null,
         "221.205.98.55",
         "用户名或密码错误。"
        ],
        [
         "3",
         "20031509",
         "2014-11-04 08:47:41",
         null,
         null,
         "222.31.51.200",
         "统一身份用户登录成功！"
        ],
        [
         "4",
         "S1405010",
         "2014-11-04 08:49:03",
         null,
         "1.2257903137349373e+17",
         "120.207.64.3",
         "单点登录研究生系统成功！"
        ]
       ],
       "shape": {
        "columns": 6,
        "rows": 5
       }
      },
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>0</th>\n",
       "      <th>1</th>\n",
       "      <th>2</th>\n",
       "      <th>3</th>\n",
       "      <th>4</th>\n",
       "      <th>5</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>S1402048</td>\n",
       "      <td>2014-11-04 08:44:46</td>\n",
       "      <td>NaN</td>\n",
       "      <td>1.225790e+17</td>\n",
       "      <td>221.205.98.55</td>\n",
       "      <td>单点登录研究生系统成功！</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>S1411023</td>\n",
       "      <td>2014-11-04 08:45:06</td>\n",
       "      <td>NaN</td>\n",
       "      <td>1.225790e+17</td>\n",
       "      <td>183.184.226.205</td>\n",
       "      <td>单点登录研究生系统成功！</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>S1402048</td>\n",
       "      <td>2014-11-04 08:46:39</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>221.205.98.55</td>\n",
       "      <td>用户名或密码错误。</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>20031509</td>\n",
       "      <td>2014-11-04 08:47:41</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>222.31.51.200</td>\n",
       "      <td>统一身份用户登录成功！</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>S1405010</td>\n",
       "      <td>2014-11-04 08:49:03</td>\n",
       "      <td>NaN</td>\n",
       "      <td>1.225790e+17</td>\n",
       "      <td>120.207.64.3</td>\n",
       "      <td>单点登录研究生系统成功！</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "          0                    1   2             3                4  \\\n",
       "0  S1402048  2014-11-04 08:44:46 NaN  1.225790e+17    221.205.98.55   \n",
       "1  S1411023  2014-11-04 08:45:06 NaN  1.225790e+17  183.184.226.205   \n",
       "2  S1402048  2014-11-04 08:46:39 NaN           NaN    221.205.98.55   \n",
       "3  20031509  2014-11-04 08:47:41 NaN           NaN    222.31.51.200   \n",
       "4  S1405010  2014-11-04 08:49:03 NaN  1.225790e+17     120.207.64.3   \n",
       "\n",
       "              5  \n",
       "0  单点登录研究生系统成功！  \n",
       "1  单点登录研究生系统成功！  \n",
       "2     用户名或密码错误。  \n",
       "3   统一身份用户登录成功！  \n",
       "4  单点登录研究生系统成功！  "
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pd.read_table('rz1.txt', sep=',', header=None)  # 使用逗号作为分隔符"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "12b0fdf9",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "base",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.8.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
